<template>
  <nav class="navbar navbar-expand-lg navbar-dark tech-navbar fixed-top">
    <div class="container">
      <router-link class="navbar-brand tech-brand" to="/">
        <div class="brand-icon">
          <i class="bi bi-cpu-fill"></i>
        </div>
        <span class="brand-text">智能银行流水解析系统</span>
        <div class="brand-glow"></div>
      </router-link>
      <button 
        class="navbar-toggler tech-toggler" 
        type="button" 
        data-bs-toggle="collapse" 
        data-bs-target="#navbarNav"
      >
        <span></span>
        <span></span>
        <span></span>
      </button>
      <div class="collapse navbar-collapse" id="navbarNav">
        <ul class="navbar-nav ms-auto tech-nav">
          <li class="nav-item">
            <router-link class="nav-link tech-nav-link" to="/">
              <i class="bi bi-house-fill"></i>
              <span>首页</span>
              <div class="nav-glow"></div>
            </router-link>
          </li>
          <li class="nav-item">
            <router-link class="nav-link tech-nav-link" to="/bank-statement">
              <i class="bi bi-bank2"></i>
              <span>银行流水管理</span>
              <div class="nav-glow"></div>
            </router-link>
          </li>
          <li class="nav-item">
            <router-link class="nav-link tech-nav-link" to="/template-management">
              <i class="bi bi-gear-fill"></i>
              <span>模板管理</span>
              <div class="nav-glow"></div>
            </router-link>
          </li>
        </ul>
      </div>
    </div>
  </nav>
</template>

<script setup lang="ts">
// 导航栏组件逻辑
</script>

<style scoped>
/* CSS 变量定义 */
:root {
  --primary-bg: #0a0a0f;
  --secondary-bg: #1a1a2e;
  --accent-color: #00d4ff;
  --neon-blue: #00d4ff;
  --neon-purple: #8b5cf6;
  --glass-bg: rgba(255, 255, 255, 0.05);
  --glass-border: rgba(255, 255, 255, 0.1);
  --cyber-gradient: linear-gradient(135deg, #00d4ff, #8b5cf6);
  --shadow-neon: 0 0 20px rgba(0, 212, 255, 0.3);
  --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* 科技导航栏 */
.tech-navbar {
  background: rgba(10, 10, 15, 0.95) !important;
  backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--glass-border);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1030;
  transition: var(--transition);
}

.tech-navbar::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: var(--cyber-gradient);
}

.tech-brand {
  display: flex;
  align-items: center;
  gap: 12px;
  font-weight: 700;
  font-size: 1.3rem;
  color: white !important;
  text-decoration: none;
  position: relative;
  transition: var(--transition);
}

.brand-icon {
  width: 40px;
  height: 40px;
  background: var(--cyber-gradient);
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.2rem;
  box-shadow: var(--shadow-neon);
  animation: pulse-glow 2s ease-in-out infinite alternate;
}

@keyframes pulse-glow {
  from { box-shadow: 0 0 10px rgba(0, 212, 255, 0.5); }
  to { box-shadow: 0 0 20px rgba(0, 212, 255, 0.8), 0 0 30px rgba(139, 92, 246, 0.4); }
}

.brand-text {
  background: var(--cyber-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.tech-toggler {
  border: none;
  padding: 8px;
  background: transparent;
  position: relative;
  width: 40px;
  height: 40px;
}

.tech-toggler span {
  display: block;
  width: 25px;
  height: 2px;
  background: var(--neon-blue);
  margin: 5px 0;
  transition: var(--transition);
  border-radius: 2px;
  box-shadow: 0 0 10px rgba(0, 212, 255, 0.5);
}

.tech-nav-link {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 12px 20px !important;
  color: rgba(255, 255, 255, 0.8) !important;
  text-decoration: none;
  border-radius: 8px;
  transition: var(--transition);
  position: relative;
  overflow: hidden;
}

.tech-nav-link::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: var(--cyber-gradient);
  opacity: 0;
  transition: var(--transition);
  z-index: -1;
}

.tech-nav-link:hover::before,
.tech-nav-link.router-link-active::before {
  opacity: 0.1;
}

.tech-nav-link:hover {
  color: white !important;
  /* 导航栏菜单鼠标引入动画 */
  /* transform: translateY(-2px); */
}

.tech-nav-link.router-link-active {
  color: var(--neon-blue) !important;
  background: rgba(0, 212, 255, 0.1);
  box-shadow: 0 0 20px rgba(0, 212, 255, 0.2);
}

.nav-glow {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: var(--cyber-gradient);
  opacity: 0;
  filter: blur(10px);
  transition: var(--transition);
  z-index: -1;
}

.tech-nav-link:hover .nav-glow {
  opacity: 0.3;
}

/* 响应式设计 */
@media (max-width: 991.98px) {
  .tech-navbar {
    padding: 0.5rem 0;
  }
  
  .brand-text {
    font-size: 1.1rem;
  }
  
  .tech-nav-link {
    margin: 4px 0;
  }
}
</style>